Skip to main content

create card

Type

command

Summary

Makes a new card with the same background (s) as the current card.

Syntax

create card [<cardName>] [in stack <stack>]

Description

Use the create card command to add a new card to the current stack.

The new card is placed after the current card. If stackName is specified, it will be placed in stackName, otherwise in the defaultStack. When the card is created, you go to the new card.

Any groups on the current card whose backgroundBehavior is set to true will be placed on the newly-created card automatically.

Parameters

NameTypeDescription

cardName

The name property of the new card. If you don't specify a cardName, the new card's name is empty.

stack

A reference or and expression that evaluates to a reference to a stack. If you specify a stack, the card will be a member of that stack, otherwise it will be a member of the defaultStack.

Examples

create card
create card "Main"
create card (field "output")
create card "Main" in stack "Stack"

command: clone, create, place, create stack

glossary: property, current card, background, current stack, variable, command

keyword: card, templateCard, it

message: newCard

object: stack

property: ID, defaultStack

Compatibility and Support

Introduced

LiveCode 1.0

OS

mac

windows

linux

ios

android

Platforms

desktop

server

mobile

Thank you for your feedback!

Was this page helpful?